#define _CRT_SECURE_NO_WARNINGS 1
#include<stdio.h>


int main()
{
	int x, y;
	for (x = 1; x <= 46; x++)
	{
		for (y = x + 2; y <= 48; y++)
		{
			if (x * (x + 1) + y * (y + 1) - (x + x + 1) - (y + y + 1) == 2015 - 1225)printf("%d %d", x, y);
		}

	}
	return 0;
}













